﻿@model List<LiteBlog.Common.Entities.Page>
<div id="headerTitle" class="float-left">
    @if(ViewBag.UseImage)
    {
        <text><img height="40" src="@Url.Content(ViewBag.ImageUrl)" /></text>   
    }
    <span class="title-text">@this.Html.Raw(ViewBag.Title)</span> 
</div>
<div id="headerMenu" class="float-right">
    <ul>
        <li>@this.Html.ActionLink("Home", "Index", "Home") </li>
        <li>@this.Html.ActionLink("Admin", "Index", "Admin") </li>
        @foreach (var page in Model)
        {
            <li>@this.Html.ActionLink(page.Title, "Index", "Page", new { id = page.FileId }, null)</li>
        }
    </ul>
</div>
<div id="headerStrip">
    @{
        var loginString = (bool)ViewData["IsAuthenticated"] ? "Logout" : "Login";
        var loginAction = (bool)ViewData["IsAuthenticated"] ? "Logout" : "Index";

    }
    <span>@ViewData["UserName"]</span>
    &nbsp;&nbsp;&nbsp;&nbsp;
    @Html.ActionLink(loginString, loginAction, "Admin", null, new { @class = "LoginLink" })
</div>